package com.cqwshzj.framework.service;/**
 * @Description:
 * @Auther: Huang Zhijin
 * @Version: 1.0.0
 * @Date: 2021/4/7 10:48
 */

import com.cqwshzj.framework.service.model.AddJobParam;

/**
 * 〈〉
 *
 * @author Huang Zhijin
 * @create 2021/4/7
 * @since 1.0.0
 */
public interface JobInfoService {


	boolean dynamicAddJob( AddJobParam param );

	boolean addJobInfoForScan( AddJobParam param );

	int scanJobInfoAndAdd();

	int updateJobProgressById( String jobId, Double progress );

	int lockAndUpdateUpdTimeById(String id, String updTime);

	boolean isConcurrencyControlByJobType(int jobType);

	int countExecutingJobOfCurrentDevIdByJobType(int jobType);

	int addJobErrRptAndSetJobFailed(String jobId, Exception e);

	int addJobErrRptAndSetJobFailed(String jobId, String message);

	int setJobAsFailedById(String jobId);

	boolean reExeJobByIdAndCron(String jobId, String cronNew);
}
